module.exports = function(sequelize, DataTypes) {
  return sequelize.define(
    "sys_permission",
    {
      id: { type: DataTypes.INTEGER, autoIncrement: true, primaryKey: true },
      sys_role_code: { type: DataTypes.STRING, unique: "rolePermissionUnique" },
      permission: {
        type: DataTypes.STRING,
        unique: "rolePermissionUnique"
      }
    },
    {
      underscored: true
    }
  );
};
